package com.cq.hd.product.service;

import com.cq.hd.common.pagination.Page;
import com.cq.hd.product.api.dto.*;
import com.cq.hd.product.api.vo.GoodsActivePageVo;
import com.cq.hd.product.api.vo.GoodsCountVo;
import com.cq.hd.product.api.vo.GoodsPageVo;
import com.cq.hd.product.po.TbGoodsPo;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

/**
 * <p>
 * 商品表 服务类
 * </p>
 *
 * @author mYunYu
 * @since 2023-11-23
 */
public interface TbGoodsService extends IService<TbGoodsPo> {

    Page<GoodsPageVo> pageGoods(GoodsPageDto goodsPageDto);

    Integer releaseGoods(GoodsReleaseDto goodsReleaseDto);

    Integer offGoods(GoodsOffDto goodsOffDto);

    Integer batchOnGoods(GoodsOnDto goodsOnDto);

    Integer onGoods(GoodsOnDto goodsOnDto);

    Integer updateGoodsStock(GoodsStockUpdateDto goodsStockUpdateDto);

    Integer updateGoodsPrice(GoodsPriceUpdateDto goodsPriceUpdateDto);

    Integer updateGoods(GoodsUpdateDto goodsUpdateDto);

    Integer deleteGoods(Long id, Long merchantId);

    Integer deleteBusinessMerchantGoods(Long id, Long businessMerchantId);

    Integer batchDeleteGoods(GoodsDelDto goodsDelDto);

    Page<GoodsActivePageVo> pageGoodsActive(GoodsActivePageDto goodsActivePageDto);

    Integer onGoodsCount(Long merchantId);

    List<GoodsCountVo> getGoodsCount(Long merchantId);

    List<GoodsCountVo> getBusinessMerchantGoodsCount(Long merchantId);

    Boolean scanOnGoodsStock();

}
